<div ng-show="pageStatus=='list'">
    <div class="search-wrap">
        <div class="search-content">
            <form name="serviceAreaSearch" ng-submit="search()">
                <table class="search-tab">
                    <tr>
                        <th width="80">用户名</th>
                        <td><input type="text" ng-model="searchParam.userName" class="common-text" placeholder="请输入"></td>
                        <th>手机号</th>
                        <td><input type="text" ng-model="searchParam.phoneNumber" class="common-text" placeholder="请输入">
                        </td>
                        <td><input type="submit" class="btn btn-primary" value="查询">
                        <td><input type="reset" ng-click="searchParam={}" class="btn btn-primary" value="重置"></td>
                    </tr>
                </table>
            </form>
        </div>
    </div>
    <div class="result-wrap">
        <div class="result-title">
            <div class="result-list">
                <a href="javascript:;" ng-click="add()"><i class="icon-font"></i>新增店员</a>
                <a href="javascript:;" ng-click="delChecked()"><i class="icon-font"></i>批量删除</a>
            </div>
        </div>
        <div class="result-content">
            <table class="result-tab" width="100%">
                <tr>
                    <th class="tc"><input class="allChoose" ng-model="master" type="checkbox"></th>
                    <th class="tc">用户名</th>
                    <th class="tc">昵称</th>
                    <th class="tc">手机号</th>
                    <th class="tc">状态</th>
                    <th class="tc">创建时间</th>
                    <th class="tc">更新时间</th>
                    <th class="tc">操作</th>
                </tr>
                <tr ng-repeat="bean in data.data">
                    <td class="tc"><input type="checkbox" name="box" ng-value="bean.userId" ng-checked="master"></td>
                    <td class="tc" ng-bind="bean.userName"></td>
                    <td class="tc" ng-bind="bean.nickName"></td>
                    <td class="tc" ng-bind="bean.phoneNumber"></td>
                    <td class="tc" ng-bind="bean.status=='Y'?'正常':'已停用'"></td>
                    <td class="tc" ng-bind="bean.createTime"></td>
                    <td class="tc" ng-bind="bean.updateTime"></td>
                    <td class="tc">
                    	<input type="button" ng-click="switchStatus(bean)" ng-value="bean.status=='Y'?'停用':'启用'" class="btn">&nbsp;
                        <input type="button" ng-click="edit(bean)" value="编辑" class="btn">&nbsp;
                        <input type="button" ng-click="del(bean.userId)" value="删除" class="btn">
                    </td>
                </tr>
            </table>
            <div class="list-page">
                <a href="javascritp:;" ng-click="fristPage()">首页</a> |
                <a href="javascritp:;" ng-click="upPage()">上一页</a> |
                第{{data.page}}页/共{{data.totalPage}}页 |
                <a href="javascritp:;" ng-click="downPage()">下一页</a> |
                <a href="javascritp:;" ng-click="endPage()">尾页</a> |
                共{{data.totalCount}}条 |
                每页显示{{data.rows}}条
            </div>
        </div>
    </div>
</div>
<div ng-show="pageStatus=='edit' || pageStatus=='add'">
    <div class="result-wrap">
        <div class="result-title">
           	 <label ng-show="pageStatus=='add'">新增店员</label>
           	 <label ng-show="pageStatus=='edit'">编辑店员</label>
        </div>
        <div class="result-content">
            <form name="editForm">
	            <table class="result-tab" width="100%" align="center">
	                <tr>
	                    <th class="tc" width="30%">用户名</th>
	                    <td class="tc" width="30%"><input type="text" name="userName" ng-model="editParam.userName" ng-maxlength="20" ng-readonly="pageStatus=='edit'" class="common-text" placeholder="店员登陆用户名" required></td>
	                    <td class="tc">
                            <span class="red" ng-show="editForm.userName.$error.required">请输入</span>
                            <span class="red" ng-show="editForm.userName.$error.maxlength">最大长度20</span>
                            <span class="green" ng-show="!editForm.userName.$error.required">OK</span>
                        </td>
	                </tr>
	                <tr>
	                    <th class="tc">昵称</th>
	                    <td class="tc"><input type="text" name="nickName" ng-model="editParam.nickName" ng-maxlength="20" class="common-text" placeholder="店员昵称" required></td>
	                    <td class="tc">
                            <span class="red" ng-show="editForm.nickName.$error.required">请输入</span>
                            <span class="red" ng-show="editForm.nickName.$error.maxlength">最大长度20</span>
                            <span class="green" ng-show="!editForm.nickName.$error.required">OK</span>
                        </td>
	                </tr>
	                <tr>
	                    <th class="tc">手机号</th>
	                    <td class="tc"><input type="text" name="phoneNumber" ng-model="editParam.phoneNumber" ng-maxlength="20" class="common-text" placeholder="店员手机号" required></td>
	                    <td class="tc">
                            <span class="red" ng-show="editForm.phoneNumber.$error.required">请输入</span>
                            <span class="red" ng-show="editForm.phoneNumber.$error.maxlength">最大长度20</span>
                            <span class="green" ng-show="!editForm.phoneNumber.$error.required">OK</span>
                        </td>
	                </tr>
	                <tr>
	                    <td colspan="3" class="tc">
	                    	<input type="button" ng-click="save()" value="保存" class="btn btn-primary">
                            <input type="reset" ng-click="editParam={}" value=" 重 置 " class="btn btn-primary">
                            <input type="button" ng-click="pageStatus='list'" value=" 返 回 " class="btn btn-primary">
                        </td>
	                </tr>
	            </table>
	        </form>
        </div>
    </div>
</div>